package com.xtyhz.constant;


/**
 * 常用的常量
 */
public class Constants {


    /**
     * 成功标记
     */
    public static final Integer SUCCESS = 200;

    /**
     * 失败标记
     */
    public static final Integer FAIL = 500;

    /**
     * 失败标记
     */
    public static final Integer FAIL_LOGIN = 401;




    /**
     * 验证码 redis key
     */
    public static final String CAPTCHA_CODE_KEY = "captcha_codes:";

    /**
     * 验证码有效期（分钟）
     */
    public static final long CAPTCHA_EXPIRATION = 5;

    public static final long ACCESS_TOKEN = 30 * 60 * 1000;//30分钟
//    public static final long ACCESS_TOKEN = 10 * 1000;//10秒

    public static final long REFRESH_TOKEN = 24 * 60 * 60 * 1000;//1天
//    public static final long REFRESH_TOKEN = 60 * 1000;//1分钟
    public static final String MAP_KEY = "loginUser";

    public static final String ACCESS_TOKEN2 = "accessToken";

    public static final String REFRESH_TOKEN2 = "refreshToken";

}
